package cn.itcast.dao;

import cn.itcast.pojo.CheckItem;
import cn.itcast.pojo.Permission;
import com.github.pagehelper.Page;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface PermissionDao {
    Integer save(Permission permission);

    Page<Permission> selectByCondition(String queryString);

    Integer delete(Integer id);

    Integer edit(Permission permission);

    Permission findByid(Integer id);

    List<Permission> findByMenuIds(List<Integer> menuIds);

    List<Permission> findAll();

    Integer findRoleIdByPermissionId(Integer permissionId);

    Integer findMenuIdByPermissionId(Integer permissionId);
}
